import request from '@/utils/request'

//分页查询
export function getKonwledgeListPage(queryList) {
  return request({
    url: `/kno/popularization/pageKnowledge`,
    method: 'post',
    data: queryList
  })
}

//通过id查找小知识,用于审核小知识
export function auditKnowById(id) {
  return request({
    url: `/kno/popularization/getKnowByid/${id}`,
    method: 'get'
  })
}

//通过id修改小知识状态，用于审核小知识
export function updateKnowState(id) {
  return request({
    url: `/kno/popularization/updateKnowStateByid/${id}`,
    method: 'post'
  })
}

//通过id删除小知识，用于管理员及用户删除小知识
export function deleteKnowByid(id) {
  return request({
    url: `/kno/popularization/deleteKnowByid/${id}`,
    method: 'post'
  })
}

